'''
Created on 13.2.2012

@author: mphkh
'''

from CashFlowUtils.IceBonds import *
from Calendar.Iceland import *
from datetime import date
from datetime import timedelta

ddate = date(2012,5,1)


bond = RVK2()

cf = bond.cashflows()

for obj in cf:
    print obj.yearfrac, obj.cfdate, obj.daysPeriod, obj.amount, obj.notional, obj.interests, obj.amortization, obj.notional-obj.amount


bond2 = FUZZBOND()

ddate2 = date(2012,4,27)

print bond2.dirtyprice(ddate2, 0.035)